#define _CRT_SECURE_NO_WARNINGS 1

#include <stdio.h>

int Fib(int n, int n1, int n2)
{
	if (n < 3)
		return n2;
	else
		return Fib(n - 1, n2, n1 + n2);
}

int main()
{
	int n = 1;
	int n1 = 1;
	int n2 = 1;
	scanf("%d", &n);
	printf("%d", Fib(n, n1, n2));
	return 0;
}